<!DOCTYPE html>
<html lang="en">

<head>
  <meta charset="UTF-8">
  <title>Document</title>
</head>

<body>
  <script>
    let arr = [1, 3, 6, 8, 2, 4]

    // filter 方法 过滤
    // >5

    arr.filter(item => {
      // return item > 5

      if (item > 5) {
        return true
      } else {
        return false
      }
    })
  </script>
</body>

</html>